package com.yh.doing.interpret_pattern.demo2;

/**
 * @program: design-patterns
 * @description:
 * @author: yangh0597@163.com
 * @date: 2022-11-27 11:52
 * @problem:
 **/
public class MultiNonTerminalExpression extends NonTerminalExpression {
    public MultiNonTerminalExpression(IExpression left, IExpression right) {
        super(left, right);
    }

    @Override
    public int interpret() {
        return this.left.interpret() * this.right.interpret();
    }
}
